/************************************************
 * Copyright (c) 2007 ~ 2009, 
 * All rights reserved.
 * Version   : 1.0
 * Author    : lengsh@gmail.com 
 * Date      : 2007.12.6
 ***********************************************/

#ifndef _EXSEARCH_DLFACADE_H______
#define _EXSEARCH_DLFACADE_H______

#include <memory>
#include <vector>
#include <string>
#include <map>
#include "IStorage.h"

using namespace std;

class DlFacade 
{
	protected:
		static DlFacade *_instance;
		IStorage *m_pStorage;
		void *dl_handle;
	public:
	protected:
		bool  Startup(const char *sofile, const char *config);
		DlFacade();
	public:
		IStorage *GetStorage();
	public:
		static DlFacade *Instance(const char *so = NULL, const char *config=NULL);
		static void Release( bool bForce = false);
		virtual ~DlFacade();
};
#endif //_EXSEARCH_DLFACADE_H______

